// 引入此文件需自建如下内容：
// footerButtons
import { CLUE_TYPE } from '@/constants/index';
import { mapGetters } from 'vuex';

export default {
  props: {
    visible: {
      type: Boolean,
      default: false,
    },
    detail: {
      type: Object,
      default: () => ({}),
    },
    planId: {
      type: [String, Number],
      default: '',
    },
    clueType: {
      type: String,
      default: 'clue',
    },
    leadsNo: {
      type: [String, Number],
      default: '',
    },
    currentNode: {
      type: Object,
      default: () => ({}),
    },
  },
  data() {
    return {};
  },
  computed: {
    ...mapGetters(['spinning']),
    processId() {
      return this.detail?.processId;
    },
    hasEdit() {
      return this.detail.leadsStatus === '0' &&
        this.detail.businessAuditStatus === '0' &&
        this.detail.transferStatus === '0'
        ? true
        : false;
    },
    filterButtons() {
      if (this.hasEdit) return this.footerButtons;
      return this.footerButtons.filter(item => !item.authKey);
    },
  },
  methods: {},
};
